/*
 * Powered By [Seven]
 * Since 2016 - 2019
 */


package com.czmh.etc.onlinepubsys.model;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;

import org.apache.commons.lang.builder.EqualsBuilder;
import org.apache.commons.lang.builder.HashCodeBuilder;
import org.apache.commons.lang.builder.ToStringBuilder;
import org.apache.commons.lang.builder.ToStringStyle;

@Entity
@Table(name = "etc_userbankcard")
public class EtcUserbankcard extends BaseModel {
	
	//alias
	public static final String TABLE_ALIAS = "EtcUserbankcard";
	public static final String ALIAS_BANK_ID = "主键";
	public static final String ALIAS_USER_ID = "用户id";
	public static final String ALIAS_APPLY_ID = "申请id";
	public static final String ALIAS_IDCARD_TYPE = "证件类型: 1-身份证,2-营业执照";
	public static final String ALIAS_IDCARD = "证件号";
	public static final String ALIAS_USERNAME = "用户姓名";
	public static final String ALIAS_IDADDRESS = "身份证地址";
	public static final String ALIAS_IDEFFDATE = "身份证有效期(yyyy-MM-dd)";
	public static final String ALIAS_IDEXPDATE = "身份证失效期(yyyy-MM-dd)";
	public static final String ALIAS_BANKACCOUNT = "二类户银行卡号(已有二类户必填)";
	public static final String ALIAS_BANKACCOUNTCODE = "二类户银行编号";
	public static final String ALIAS_BANKCODE = "一类户银行编号";
	public static final String ALIAS_BANKMOBILE = "银行预留手机号";
	public static final String ALIAS_BANKNAME = "一类户银行名称";
	public static final String ALIAS_BANKNO = "一类户银行卡号(开二类户必填)";
	 
	//可以直接使用: @Length(max=50,message="用户名长度不能大于50")显示错误消息
	//columns START
	@Column(name = "bank_id")
	@Id
	private java.lang.String bank_id;
	@Column(name = "user_id")
	private java.lang.String user_id;
	@Column(name = "apply_id")
	private java.lang.String apply_id;
	@Column(name = "idcard_type")
	private java.lang.Integer idcard_type;
	@Column(name = "idcard")
	private java.lang.String idcard;
	@Column(name = "username")
	private java.lang.String username;
	@Column(name = "idaddress")
	private java.lang.String idaddress;
	@Column(name = "ideffdate")
	private java.util.Date ideffdate;
	@Column(name = "idexpdate")
	private java.util.Date idexpdate;
	@Column(name = "bankaccount")
	private java.lang.String bankaccount;
	@Column(name = "bankaccountcode")
	private java.lang.String bankaccountcode;
	@Column(name = "bankcode")
	private java.lang.String bankcode;
	@Column(name = "bankmobile")
	private java.lang.String bankmobile;
	@Column(name = "bankname")
	private java.lang.String bankname;
	@Column(name = "bankno")
	private java.lang.String bankno;
	//columns END

	public EtcUserbankcard(){
	}

	public EtcUserbankcard(
		java.lang.String bank_id
	){
		this.bank_id = bank_id;
	}

	/**  
	 * 设置主键  
	 * @param bank_id 主键  
	 */  
	public void setBank_id(java.lang.String bank_id) {
		this.bank_id = bank_id;
	}
	
	/**  
	 * 获取主键   
	 * @return bank_id 主键   
	 */
	public java.lang.String getBank_id() {
		return this.bank_id;
	}
	/**  
	 * 设置用户id  
	 * @param user_id 用户id  
	 */  
	public void setUser_id(java.lang.String user_id) {
		this.user_id = user_id;
	}
	
	/**  
	 * 获取用户id   
	 * @return user_id 用户id   
	 */
	public java.lang.String getUser_id() {
		return this.user_id;
	}
	/**  
	 * 设置申请id  
	 * @param apply_id 申请id  
	 */  
	public void setApply_id(java.lang.String apply_id) {
		this.apply_id = apply_id;
	}
	
	/**  
	 * 获取申请id   
	 * @return apply_id 申请id   
	 */
	public java.lang.String getApply_id() {
		return this.apply_id;
	}
	/**  
	 * 设置证件类型: 1-身份证,2-营业执照  
	 * @param idcard_type 证件类型: 1-身份证,2-营业执照  
	 */  
	public void setIdcard_type(java.lang.Integer idcard_type) {
		this.idcard_type = idcard_type;
	}
	
	/**  
	 * 获取证件类型: 1-身份证,2-营业执照   
	 * @return idcard_type 证件类型: 1-身份证,2-营业执照   
	 */
	public java.lang.Integer getIdcard_type() {
		return this.idcard_type;
	}
	/**  
	 * 设置证件号  
	 * @param idcard 证件号  
	 */  
	public void setIdcard(java.lang.String idcard) {
		this.idcard = idcard;
	}
	
	/**  
	 * 获取证件号   
	 * @return idcard 证件号   
	 */
	public java.lang.String getIdcard() {
		return this.idcard;
	}
	/**  
	 * 设置用户姓名  
	 * @param username 用户姓名  
	 */  
	public void setUsername(java.lang.String username) {
		this.username = username;
	}
	
	/**  
	 * 获取用户姓名   
	 * @return username 用户姓名   
	 */
	public java.lang.String getUsername() {
		return this.username;
	}
	/**  
	 * 设置身份证地址  
	 * @param idaddress 身份证地址  
	 */  
	public void setIdaddress(java.lang.String idaddress) {
		this.idaddress = idaddress;
	}
	
	/**  
	 * 获取身份证地址   
	 * @return idaddress 身份证地址   
	 */
	public java.lang.String getIdaddress() {
		return this.idaddress;
	}
	/**  
	 * 设置身份证有效期(yyyy-MM-dd)  
	 * @param ideffdate 身份证有效期(yyyy-MM-dd)  
	 */  
	public void setIdeffdate(java.util.Date ideffdate) {
		this.ideffdate = ideffdate;
	}
	
	/**  
	 * 获取身份证有效期(yyyy-MM-dd)   
	 * @return ideffdate 身份证有效期(yyyy-MM-dd)   
	 */
	public java.util.Date getIdeffdate() {
		return this.ideffdate;
	}
	/**  
	 * 设置身份证失效期(yyyy-MM-dd)  
	 * @param idexpdate 身份证失效期(yyyy-MM-dd)  
	 */  
	public void setIdexpdate(java.util.Date idexpdate) {
		this.idexpdate = idexpdate;
	}
	
	/**  
	 * 获取身份证失效期(yyyy-MM-dd)   
	 * @return idexpdate 身份证失效期(yyyy-MM-dd)   
	 */
	public java.util.Date getIdexpdate() {
		return this.idexpdate;
	}
	/**  
	 * 设置二类户银行卡号(已有二类户必填)  
	 * @param bankaccount 二类户银行卡号(已有二类户必填)  
	 */  
	public void setBankaccount(java.lang.String bankaccount) {
		this.bankaccount = bankaccount;
	}
	
	/**  
	 * 获取二类户银行卡号(已有二类户必填)   
	 * @return bankaccount 二类户银行卡号(已有二类户必填)   
	 */
	public java.lang.String getBankaccount() {
		return this.bankaccount;
	}
	/**  
	 * 设置二类户银行编号  
	 * @param bankaccountcode 二类户银行编号  
	 */  
	public void setBankaccountcode(java.lang.String bankaccountcode) {
		this.bankaccountcode = bankaccountcode;
	}
	
	/**  
	 * 获取二类户银行编号   
	 * @return bankaccountcode 二类户银行编号   
	 */
	public java.lang.String getBankaccountcode() {
		return this.bankaccountcode;
	}
	/**  
	 * 设置一类户银行编号  
	 * @param bankcode 一类户银行编号  
	 */  
	public void setBankcode(java.lang.String bankcode) {
		this.bankcode = bankcode;
	}
	
	/**  
	 * 获取一类户银行编号   
	 * @return bankcode 一类户银行编号   
	 */
	public java.lang.String getBankcode() {
		return this.bankcode;
	}
	/**  
	 * 设置银行预留手机号  
	 * @param bankmobile 银行预留手机号  
	 */  
	public void setBankmobile(java.lang.String bankmobile) {
		this.bankmobile = bankmobile;
	}
	
	/**  
	 * 获取银行预留手机号   
	 * @return bankmobile 银行预留手机号   
	 */
	public java.lang.String getBankmobile() {
		return this.bankmobile;
	}
	/**  
	 * 设置一类户银行名称  
	 * @param bankname 一类户银行名称  
	 */  
	public void setBankname(java.lang.String bankname) {
		this.bankname = bankname;
	}
	
	/**  
	 * 获取一类户银行名称   
	 * @return bankname 一类户银行名称   
	 */
	public java.lang.String getBankname() {
		return this.bankname;
	}
	/**  
	 * 设置一类户银行卡号(开二类户必填)  
	 * @param bankno 一类户银行卡号(开二类户必填)  
	 */  
	public void setBankno(java.lang.String bankno) {
		this.bankno = bankno;
	}
	
	/**  
	 * 获取一类户银行卡号(开二类户必填)   
	 * @return bankno 一类户银行卡号(开二类户必填)   
	 */
	public java.lang.String getBankno() {
		return this.bankno;
	}

	public String toString() {
		return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
			.append("bank_id",getBank_id())
			.append("user_id",getUser_id())
			.append("apply_id",getApply_id())
			.append("idcard_type",getIdcard_type())
			.append("idcard",getIdcard())
			.append("username",getUsername())
			.append("idaddress",getIdaddress())
			.append("ideffdate",getIdeffdate())
			.append("idexpdate",getIdexpdate())
			.append("bankaccount",getBankaccount())
			.append("bankaccountcode",getBankaccountcode())
			.append("bankcode",getBankcode())
			.append("bankmobile",getBankmobile())
			.append("bankname",getBankname())
			.append("bankno",getBankno())
			.toString();
	}
	
	public int hashCode() {
		return new HashCodeBuilder()
			.append(getBank_id())
			.toHashCode();
	}
	
	public boolean equals(Object obj) {
		if(obj instanceof EtcUserbankcard == false) {
			return false;
		}
		if(this == obj) {
			return true;
		}
		EtcUserbankcard other = (EtcUserbankcard)obj;
		return new EqualsBuilder()
			.append(getBank_id(),other.getBank_id())
			.isEquals();
	}
}

